﻿@model IEnumerable<LOMBARDISPICK.Model.NFLTeam>

@{
	ViewBag.Title = "Index";
}

<div class="wrapper row1">
  <header id="header">
	<hgroup>
	  <h1>NFL Teams</h1>
	</hgroup>
  </header>
</div>

<!-- content -->
<div class="wrapper row2">
	<div id="container">
	<!-- ################################################################################################ -->

<p>
	@Html.ActionLink("Create New", "Create")
</p>

<table class="applySortFilterDataTable">
	<thead>
		<tr>
			<th></th>
			<th>
				@Html.LabelFor(model => model.SingleOrDefault().TeamName)
			</th>
			<th>
				@Html.LabelFor(model => model.SingleOrDefault().TeamNameAbbreviations)
			</th>			
			<th>Team Logo</th>
		</tr>
	</thead>
	<tbody>
@foreach (var item in Model) {
		<tr>
			<td>
				@Html.ActionLink("Edit", "Edit", new { id=item.NFLTeamsID }) |
				@Html.ActionLink("Details", "Details", new { id = item.NFLTeamsID }) |
				@Html.ActionLink("Delete", "Delete", new { id = item.NFLTeamsID })
			</td>
			<td>
				@item.TeamName
			</td>
			<td>
				@item.TeamNameAbbreviations
			</td>
			<td>          
				<img src="@Url.Action("GetImage", "NFLTeams", new { id = @item.NFLTeamsID })" />
			</td>

		</tr>
}
	</tbody>

</table>

	<!-- ################################################################################################ -->
	<div class="clear"></div>
	</div>
</div>